.class public Lcom/xingbook/cinema/c/c;
.super Landroid/widget/RelativeLayout;

# interfaces
.implements Landroid/view/View$OnClickListener;
.implements Lcom/xingbook/park/c/a/n;


# instance fields
.field private a:Landroid/widget/ImageView;

.field private b:Landroid/widget/TextView;

.field private c:Landroid/widget/TextView;

.field private d:Landroid/view/View;

.field private e:Lcom/xingbook/cinema/b/a;

.field private f:Landroid/content/Context;

.field private g:F

.field private h:Lcom/xingbook/cinema/c/a;


# direct methods
.method public constructor <init>(Landroid/content/Context;FLcom/xingbook/cinema/c/a;Z)V
    .locals 0

    invoke-direct {p0, p1}, Landroid/widget/RelativeLayout;-><init>(Landroid/content/Context;)V

    iput-object p1, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    iput p2, p0, Lcom/xingbook/cinema/c/c;->g:F

    iput-object p3, p0, Lcom/xingbook/cinema/c/c;->h:Lcom/xingbook/cinema/c/a;

    invoke-virtual {p0, p4}, Lcom/xingbook/cinema/c/c;->setupView(Z)V

    return-void
.end method


# virtual methods
.method public a(Lcom/xingbook/b/n;IZ)V
    .locals 6

    const/16 v1, 0x8

    const/4 v3, 0x0

    :try_start_0
    check-cast p1, Lcom/xingbook/cinema/b/a;

    iput-object p1, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    :goto_0
    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    if-nez v0, :cond_0

    invoke-virtual {p0, v1}, Lcom/xingbook/cinema/c/c;->setVisibility(I)V

    :goto_1
    return-void

    :catch_0
    move-exception v0

    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    const/4 v0, 0x0

    iput-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    goto :goto_0

    :cond_0
    invoke-virtual {p0, v3}, Lcom/xingbook/cinema/c/c;->setVisibility(I)V

    if-eqz p3, :cond_1

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    invoke-virtual {v0, v3}, Landroid/view/View;->setVisibility(I)V

    :goto_2
    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-virtual {v0, v3}, Lcom/xingbook/cinema/b/a;->d(Z)Ljava/lang/String;

    move-result-object v0

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    const/4 v2, -0x1

    const/4 v4, 0x1

    const/4 v5, 0x0

    invoke-static/range {v0 .. v5}, Lcom/xingbook/c/k;->a(Ljava/lang/String;Landroid/widget/ImageView;IZZF)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-virtual {v1}, Lcom/xingbook/cinema/b/a;->y()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-virtual {v1}, Lcom/xingbook/cinema/b/a;->u()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    goto :goto_1

    :cond_1
    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V

    goto :goto_2
.end method

.method public getResType()I
    .locals 1

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-virtual {v0}, Lcom/xingbook/cinema/b/a;->s()I

    move-result v0

    :goto_0
    return v0

    :cond_0
    const/16 v0, 0x61

    goto :goto_0
.end method

.method public onClick(Landroid/view/View;)V
    .locals 2

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    if-eqz v0, :cond_1

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->h:Lcom/xingbook/cinema/c/a;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->h:Lcom/xingbook/cinema/c/a;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-interface {v0, v1}, Lcom/xingbook/cinema/c/a;->a(Lcom/xingbook/cinema/b/a;)Z

    move-result v0

    if-nez v0, :cond_1

    :cond_0
    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->e:Lcom/xingbook/cinema/b/a;

    invoke-static {v0, v1}, Lcom/xingbook/c/t;->a(Landroid/content/Context;Lcom/xingbook/b/n;)V

    :cond_1
    return-void
.end method

.method public setupView(Z)V
    .locals 9

    const/4 v8, 0x1

    const/high16 v7, 0x41e0

    const/4 v6, 0x0

    const/4 v5, -0x2

    const v4, 0x7f0a0043

    invoke-virtual {p0, p0}, Lcom/xingbook/cinema/c/c;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    if-eqz p1, :cond_0

    sget v0, Lcom/xingbook/park/c/a/y;->a:I

    int-to-float v0, v0

    iget v1, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v0, v1

    float-to-int v0, v0

    invoke-virtual {p0, v0, v6, v0, v6}, Lcom/xingbook/cinema/c/c;->setPadding(IIII)V

    :cond_0
    new-instance v0, Landroid/view/View;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v0, v1}, Landroid/view/View;-><init>(Landroid/content/Context;)V

    iput-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    const v1, 0x7f0a004d

    invoke-virtual {v0, v1}, Landroid/view/View;->setId(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    new-instance v1, Landroid/widget/RelativeLayout$LayoutParams;

    sget v2, Lcom/xingbook/park/c/a/y;->b:I

    int-to-float v2, v2

    iget v3, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v2, v3

    float-to-int v2, v2

    invoke-direct {v1, v8, v2}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    invoke-virtual {v0, v1}, Landroid/view/View;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    const/16 v1, 0x8

    invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->d:Landroid/view/View;

    invoke-virtual {p0, v0}, Lcom/xingbook/cinema/c/c;->addView(Landroid/view/View;)V

    new-instance v0, Landroid/widget/ImageView;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v0, v1}, Landroid/widget/ImageView;-><init>(Landroid/content/Context;)V

    iput-object v0, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    invoke-virtual {v0, v4}, Landroid/widget/ImageView;->setId(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    sget-object v1, Landroid/widget/ImageView$ScaleType;->FIT_XY:Landroid/widget/ImageView$ScaleType;

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setScaleType(Landroid/widget/ImageView$ScaleType;)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    const v1, -0x333334

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setBackgroundColor(I)V

    new-instance v0, Landroid/widget/RelativeLayout$LayoutParams;

    const/high16 v1, 0x43ac

    iget v2, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v1, v2

    float-to-int v1, v1

    const/high16 v2, 0x4341

    iget v3, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v2, v3

    float-to-int v2, v2

    invoke-direct {v0, v1, v2}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    const/4 v1, 0x3

    const v2, 0x7f0a004d

    invoke-virtual {v0, v1, v2}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    invoke-virtual {v1, v0}, Landroid/widget/ImageView;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->a:Landroid/widget/ImageView;

    invoke-virtual {p0, v0}, Lcom/xingbook/cinema/c/c;->addView(Landroid/view/View;)V

    new-instance v0, Landroid/widget/RelativeLayout;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v0, v1}, Landroid/widget/RelativeLayout;-><init>(Landroid/content/Context;)V

    const/high16 v1, 0x40c0

    iget v2, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v1, v2

    float-to-int v1, v1

    invoke-virtual {v0, v1, v1, v1, v1}, Landroid/widget/RelativeLayout;->setPadding(IIII)V

    const/high16 v1, 0x4d00

    invoke-virtual {v0, v1}, Landroid/widget/RelativeLayout;->setBackgroundColor(I)V

    new-instance v1, Landroid/widget/RelativeLayout$LayoutParams;

    invoke-direct {v1, v5, v5}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    const/4 v2, 0x5

    invoke-virtual {v1, v2, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    const/4 v2, 0x7

    invoke-virtual {v1, v2, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    const/16 v2, 0x8

    invoke-virtual {v1, v2, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    invoke-virtual {v0, v1}, Landroid/widget/RelativeLayout;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    invoke-virtual {p0, v0}, Lcom/xingbook/cinema/c/c;->addView(Landroid/view/View;)V

    new-instance v1, Landroid/view/View;

    iget-object v2, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v1, v2}, Landroid/view/View;-><init>(Landroid/content/Context;)V

    const v2, 0x7f0a0044

    invoke-virtual {v1, v2}, Landroid/view/View;->setId(I)V

    iget v2, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v2, v7

    float-to-int v2, v2

    new-instance v3, Landroid/widget/RelativeLayout$LayoutParams;

    invoke-direct {v3, v2, v2}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    const/16 v2, 0xf

    invoke-virtual {v3, v2}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(I)V

    invoke-virtual {v1, v3}, Landroid/view/View;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    const v2, 0x7f0202b6

    invoke-virtual {v1, v2}, Landroid/view/View;->setBackgroundResource(I)V

    invoke-virtual {v0, v1}, Landroid/widget/RelativeLayout;->addView(Landroid/view/View;)V

    new-instance v1, Landroid/widget/TextView;

    iget-object v2, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v1, v2}, Landroid/widget/TextView;-><init>(Landroid/content/Context;)V

    iput-object v1, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    iget v2, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v2, v7

    invoke-virtual {v1, v6, v2}, Landroid/widget/TextView;->setTextSize(IF)V

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    const/4 v2, -0x1

    invoke-virtual {v1, v2}, Landroid/widget/TextView;->setTextColor(I)V

    new-instance v1, Landroid/widget/RelativeLayout$LayoutParams;

    invoke-direct {v1, v5, v5}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    const v2, 0x7f0a0044

    invoke-virtual {v1, v8, v2}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    const/16 v2, 0xf

    invoke-virtual {v1, v2}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(I)V

    iget-object v2, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    invoke-virtual {v2, v1}, Landroid/widget/TextView;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->b:Landroid/widget/TextView;

    invoke-virtual {v0, v1}, Landroid/widget/RelativeLayout;->addView(Landroid/view/View;)V

    new-instance v0, Landroid/widget/TextView;

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->f:Landroid/content/Context;

    invoke-direct {v0, v1}, Landroid/widget/TextView;-><init>(Landroid/content/Context;)V

    iput-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    const v1, -0x99999a

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setTextColor(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    invoke-virtual {v0, v8}, Landroid/widget/TextView;->setGravity(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    iget v1, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v1, v7

    invoke-virtual {v0, v6, v1}, Landroid/widget/TextView;->setTextSize(IF)V

    const/high16 v0, 0x41c0

    iget v1, p0, Lcom/xingbook/cinema/c/c;->g:F

    mul-float/2addr v0, v1

    float-to-int v0, v0

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    invoke-virtual {v1, v6, v0, v6, v0}, Landroid/widget/TextView;->setPadding(IIII)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    const/4 v1, 0x2

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setMaxLines(I)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    sget-object v1, Landroid/text/TextUtils$TruncateAt;->END:Landroid/text/TextUtils$TruncateAt;

    invoke-virtual {v0, v1}, Landroid/widget/TextView;->setEllipsize(Landroid/text/TextUtils$TruncateAt;)V

    new-instance v0, Landroid/widget/RelativeLayout$LayoutParams;

    invoke-direct {v0, v5, v5}, Landroid/widget/RelativeLayout$LayoutParams;-><init>(II)V

    const/4 v1, 0x3

    invoke-virtual {v0, v1, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    const/4 v1, 0x5

    invoke-virtual {v0, v1, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    const/4 v1, 0x7

    invoke-virtual {v0, v1, v4}, Landroid/widget/RelativeLayout$LayoutParams;->addRule(II)V

    iget-object v1, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    invoke-virtual {v1, v0}, Landroid/widget/TextView;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    iget-object v0, p0, Lcom/xingbook/cinema/c/c;->c:Landroid/widget/TextView;

    invoke-virtual {p0, v0}, Lcom/xingbook/cinema/c/c;->addView(Landroid/view/View;)V

    return-void
.end method
